﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Aribaccio.Device
{
    /// <summary>
    /// 功能码类型类
    /// </summary>
    public enum ModbusFuncCode
    {
        /// <summary>
        /// 读取线圈状态
        /// </summary>
        ReadCoilStatus = 01,
        /// <summary>
        /// 读取输入状态
        /// </summary>
        ReadInputStatus = 02,
        /// <summary>
        /// 读取保持存储器
        /// </summary>
        ReadHoldingRegisters = 03,
        /// <summary>
        /// 读取输入存储器
        /// </summary>
        ReadInputRegisters = 04,
        /// <summary>
        /// 写入单个线圈
        /// </summary>
        WriteSingleCoil = 05,
        /// <summary>
        /// 写个单个存储器(离散量线圈)
        /// </summary>
        WriteSingleRegisters = 06,
        /// <summary>
        /// 写一组线圈
        /// </summary>
        WriteMultipleCoils = 15,
        /// <summary>
        /// 写入多个存储器(写一组保持寄存器)
        /// </summary>
        WriteMultipleRegisters = 16
    }
}
